import { BroadCastCall } from "broadCast/BroadCastCall";
import { MessageBlock } from "../../../Framework/MQ/MessageBlock";
import { SMagicTowerStatues } from "../../../Message/Public/SMagicTowerStatues";
import { SceneConfig } from "../resource/SceneConfig";
import { ThingUtil } from "../scene/layer/utils/ThingUtil";
//class MagicTowerStatueCommand
    
    export  class MagicTowerStatueCommand extends BroadCastCall
    {
        constructor(arg1: Object)
        {
            super(arg1);
            return;
        }

        public /* override */ call(arg1: MessageBlock): void
        {
            var loc1=arg1.messageBase as SMagicTowerStatues;
            var loc2=SceneConfig.instance.getSceneInfo(loc1.mapId);
            if (loc2) 
            {
                loc2.updateStatue(loc1.statues);
            }
            ThingUtil.isStatueChange = true;
            return;
        }
    }
